<%--
  Created by IntelliJ IDEA.
  User: Yuanao
  Date: 2021/10/21
  Time: 14:48
  File: signin.jsp
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>登录</title>
    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
</head>
<body>
<!-- 在这里输入内容 -->
<label for="id">用户名</label><input id="id" type="text">
<label for="password">密码</label><input id="password" type="password" placeholder="" datatype="">
<button onclick="myClick()">登录</button>

<script>
    
    function myClick() {
        let $id = $("#id");
        let $password = $("#password");

        let id = $id.val();
        let password = $password.val();

        if (id == "" || password == "") {
            alert("请填写密码或用户名");
            return;
        }

        $.post("",{
            id:id,
            password:password
        },(data,status) => {

        });







    }
    
</script>
</body>
</html>